# from flask import Flask
# from flask import request
import flask

app = flask.Flask(__name__)
# app = Flask(__name__)

# 签到接口
@app.route("/sign",methods=["POST"])
def sign():
    # 接收请求，接收请求带来的参数
    name = flask.request.values.get("name")
    number = flask.request.values.get("number")
    print(name + "--" + number)
    return "good:" + name + "--" + number

@app.route("/")
def index():
    return "index.html"

# 签到页面
@app.route("/reg.html")
def reg():
    try:
        fobj=open("reg.html","rb")
        data=fobj.read()
        fobj.close()
        return data
    except Exception as err:
        return str(err)


app.run(port=8888,host="0.0.0.0")